<template>
  <section class="test">
    <form id="formdata" enctype="multipart/form-data" method="post">
      <input type="file" name="file" />
      <button type="submit" @click="getForm">upload</button>
    </form>
  </section>
</template>
<script>
import axios from "axios"
export default {
  data() {
    return {
    }
  },
  methods: {
    getForm() {
      axios.post("/admin/material", { data: new FormData(document.querySelector("#formdata")) })

    }
  },
  mounted() {

  }
}
</script>

<style scoped>

</style>
